package framework.office.apache.poi.xls;
import java.io.FileInputStream;

import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.Iterator;

import org.apache.poi.hssf.usermodel.HSSFCell;
import org.apache.poi.hssf.usermodel.HSSFRow;
import org.apache.poi.hssf.usermodel.HSSFSheet;
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
import org.apache.poi.poifs.filesystem.POIFSFileSystem;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.Row;
public class Out {
	public static String path = "C:/Users/K/Desktop/1/test.xls";
	public static void main(String[] args) throws Exception {
		out();
	}
	static void out() throws Exception {
		HSSFWorkbook bk = new HSSFWorkbook(new POIFSFileSystem(new FileInputStream(path)));
		HSSFSheet sheet = bk.getSheetAt(0);
		Iterator<Row> rowit = sheet.rowIterator();
		HSSFRow row = sheet.getRow(0);
		Iterator<Cell> cellit = row.cellIterator();
		HSSFCell cell = row.getCell(0);
		System.out.println(cell);
	}
}
